#pragma once

#include "..\ImageCapMan\ImgCapPlugHeader.h"
#include "DDThread.h"
#include <vfw.h>

class ImageRecord : public DDThread
{
public:
	ImageRecord(void);
	~ImageRecord(void);


public:
	int ImgRecord(zkImgBitInfo *pImgBitInfo);

public:
	int StartRecord(char *pFileName);
	int StopRecord();

public:
	virtual int DDThdDispatch(HANDLE hExitEvent = NULL);


protected:
	COMPVARS m_xCOMPVARS;


private:
	AVISTREAMINFO m_strhdr;
	PAVIFILE      m_pfile;
	PAVISTREAM    m_ps; 
	PAVISTREAM    m_pComStream;
	int           m_nFrames; 
	AVICOMPRESSOPTIONS m_CompressOption; 

private:
	int   m_nBufSize;
	BYTE *m_pBuffer;

};
